package com.origin.file.service;

import com.origin.file.entity.dto.file.DownloadFileDTO;
import com.origin.file.entity.dto.file.PreviewDTO;
import com.origin.file.entity.dto.file.UploadFileDTO;
import com.origin.file.entity.vo.file.UploadFileVO;
import com.origin.oss.entity.FileInfo;
import com.origin.oss.specification.domain.multipart.response.QuickUploadResp;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * @author MAC
 */
public interface IFiletransferService {

    /**
     * 快速上传
     */
    QuickUploadResp uploadFileSpeed(UploadFileDTO uploadFileDTO);

    /**
     * 上传文件
     */
    void uploadFileChunk(HttpServletRequest request, UploadFileDTO UploadFileDto, String userId);

    void downloadFile(HttpServletResponse httpServletResponse, DownloadFileDTO downloadFileDTO);

    void downloadUserFileList(HttpServletResponse httpServletResponse, String filePath, String fileName, List<String> userFileIds);

    void previewFile(HttpServletResponse httpServletResponse, PreviewDTO previewDTO);

    void previewPictureFile(HttpServletResponse httpServletResponse, PreviewDTO previewDTO);

    void deleteFile(FileInfo fileBean);

    Long selectStorageSizeByUserId(String userId);
}
